<?php

class Carta extends MY_Model {

 
    function Carta()
    {
        // Call the Model constructor
        parent::MY_Model();
	
	$this->nombreTabla = "carta";
	$this->idT1= "idCarta";
	$this->nombreCampo="descripcion";

		$this->campos[] = array("realname" => "idTipoCarta",
					"clase" => "opciones",
					"label" => "Tipo de Carta",
					"modelo" => "Tipocarta",
					"rules" => "required|integer");

		$this->campos[] = array("realname" => "idResto",
					"clase" => "opciones",
					"label" => "Restaurant",
					"modelo" => "Restaurant",
					"rules" => "required|integer");

		$this->campos[] = array("realname" => "descripcion",
					"clase" => "textarea",
					"label" => "Descripcion",
					"rules" => "required|alpha_numeric_space|min_length[3]|max_length[45]");

		
		$this->campos[] = array("realname" => "mostrarPrecio",
					"clase" => "text",
					"label" => "Mostrar Precio(0-No,1-Si)",
					"rules" => "required|integer|exact_length[1]");

		// Nombre de los modelos que son hijos   nombremodelo=>label
		 $this->hijos = array('plato'=>'Plato');
    }
     


 
}


?>
